import request from '@/utils/request'
import {formDataFun} from './public'

export function getImageCode() {
  return request({
    url: '/ht-auth/oauth/captcha',
    method: 'get'
  })
}

// 特效列表
export function effectPageList(data) {
  return request({
    url: '/ht-trial-manage/effect/pageList',
    method: 'post',
    data:data
  })
}
//特效删除
export function effectRemoves(v) {
  return request({
    url: '/ht-trial-manage/effect/removes',
    method: 'post',
    data: v
  })
}
export function effectUpdate(v){
  return request({
      url: '/ht-trial-manage/effect/update',
      method: 'post',
      data: v
    })
}
export function effectInsert(v){
  return request({
      url: '/ht-trial-manage/effect/insert',
      method: 'post',
      data: v
    })
}
// -----试验
// 列表
export function trialSubjectPpageList(data) {
  return request({
    url: '/ht-trial-manage/trialSubject/pageList',
    method: 'post',
    data:data
  })
}
//标签————————
export function addTrialLabel(v) {
  return request({
    url: '/ht-trial-manage/label/insert',
    method: 'post',
    data: v
  })
}
export function removeLable(v) {
  return request({
    url: '/ht-trial-manage/label/removes',
    method: 'post',
    data: v
  })
}
export function trialLabelUpdate(v) {
  return request({
    url: '/ht-trial-manage/label/update',
    method: 'post',
    data: v
  })
}
export function trialLabelPageList(v) {
  return request({
    url: '/ht-trial-manage/label/pageList',
    method: 'post',
    data: v
  })
}



//类型管理-------------------------------------------
export function addModelTypePages(v){
  return request({
      url: '/ht-trial-manage/modelType/insert',
      method: 'post',
      data: v
    })
}
export function modelTypeRemoves(v){
  return request({
      url: '/ht-trial-manage/modelType/removes',
      method: 'post',
      data: v
    })
}
export function updateModelTypePages(v){
  return request({
      url: '/ht-trial-manage/modelType/update',
      method: 'post',
      data: v
    })
}
export function modelTypePageList(v){
  return request({
      url: '/ht-trial-manage/modelType/pageList',
      method: 'post',
      data: v
    })
}


// 厂商管理------------

export function addFirmInsert(v){
  return request({
      url: '/ht-trial-manage/firm/insert',
      method: 'post',
      data: v
    })
}
export function firmRemoves(v){
  return request({
      url: '/ht-trial-manage/firm/removes',
      method: 'post',
      data: v
    })
}
export function updateFirmUpdate(v){
  return request({
      url: '/ht-trial-manage/firm/update',
      method: 'post',
      data: v
    })
}

//// 供应商
export function getFirmPageList(v){
  return request({
      url: '/ht-trial-manage/firm/pageList',
      method: 'post',
      data: v
    })
}

// 试验基本信息管理------------

export function addInfoInsert(v){
  return request({
      url: '/ht-trial-manage/info/insert',
      method: 'post',
      data: v
    })
}
export function infoRemove(v){
  return request({
      url: '/ht-trial-manage/info/removes',
      method: 'post',
      data: v
    })
}
export function updateInfoUpdate(v){
  return request({
      url: '/ht-trial-manage/info/update',
      method: 'post',
      data: v
    })
}
export function getInfoPageList(v){
  return request({
      url: '/ht-trial-manage/info/pageList',
      method: 'post',
      data: v
    })
}


// 流程阶段管理------------

export function addStageMainInsert(v){
  return request({
      url: '/ht-trial-manage/stageMain/insert',
      method: 'post',
      data: v
    })
}
export function stageMainRemoves(v){
  return request({
      url: '/ht-trial-manage/stageMain/removes',
      method: 'post',
      data: v
    })
}
export function updateStageMainUpdate(v){
  return request({
      url: '/ht-trial-manage/stageMain/update',
      method: 'post',
      data: v
    })
}
export function getstageMainPageList(v){
  return request({
      url: '/ht-trial-manage/stageMain/pageList',
      method: 'post',
      data: v
    })
}


// 试验对象关联管理------------
export function addinfoSubjectinsert(v){
  return request({
      url: '/ht-trial-manage/infoSubject/insert',
      method: 'post',
      data: v
    })
}
export function infoSubjectRemoves(v){
  return request({
      url: '/ht-trial-manage/infoSubject/removes',
      method: 'post',
      data: v
    })
}
export function infoSubjectupdate(v){
  return request({
      url: '/ht-trial-manage/infoSubject/update',
      method: 'post',
      data: v
    })
}
export function getinfoSubjectpageList(v){
  return request({
      url: '/ht-trial-manage/infoSubject/pageList',
      method: 'post',
      data: v
    })
}

// 试验模型对象管理
export function addsubjectinsert(v){
  return request({
      url: '/ht-trial-manage/subject/insert',
      method: 'post',
      data: v
    })
}
export function subjectremoves(v){
  return request({
      url: '/ht-trial-manage/subject/removes',
      method: 'post',
      data: v
    })
}
export function subjectupdate(v){
  return request({
      url: '/ht-trial-manage/subject/update',
      method: 'post',
      data: v
    })
}
export function getsubjectpageList(v){
  return request({
      url: '/ht-trial-manage/subject/pageList',
      method: 'post',
      data: v
    })
}
export function getsubjectpageAllList(v){
  return request({
      url: '/ht-trial-manage/subject/list',
      method: 'post',
      data: v
    })
}


// 模型管理------------


export function addmodelpageList(v){
  return request({
      url: '/ht-trial-manage/model/insert',
      method: 'post',
      data: v
    })
}
export function modelRemoves(v){
  return request({
      url: '/ht-trial-manage/model/removes',
      method: 'post',
      data: v
    })
}
export function modelupdate(v){
  return request({
      url: '/ht-trial-manage/model/update',
      method: 'post',
      data: v
    })
}
export function getmodelpageList(v){
  return request({
      url: '/ht-trial-manage/model/pageList',
      method: 'post',
      data: v
    })
}

export function codeManagepageList(v){
  return request({
      url: '/ht-trial-manage/codeManage/pageList',
      method: 'post',
      data: v
    })
}
export function codeManagelistByCodeMain(v){
  return request({
      url: '/ht-trial-manage/codeManage/listByCodeMain?codeMain='+v,
      method: 'get',
    })
}
export function codeMainlist(v){
  return request({
      url: '/ht-trial-manage/codeMain/list',
      method: 'get',
    })
}
export function codeMainpageList(v){
  return request({
      url: '/ht-trial-manage/codeMain/pageList',
      method: 'post',
      data:v
    })
}
export function codeMainupdate(v){
  return request({
      url: '/ht-trial-manage/codeMain/update',
      method: 'post',
      data:v
    })
}
export function codeMaininsert(v){
  return request({
      url: '/ht-trial-manage/codeMain/insert',
      method: 'post',
      data:v
    })
}
export function codeMainremoves(v){
  return request({
      url: '/ht-trial-manage/codeMain/removes',
      method: 'post',
      data:v
    })
}

export function schemepageList(v){
  return request({
      url: '/ht-trial-manage/scheme/pageList',
      method: 'post',
      data:v
    })
}
